﻿namespace Preactor.ObjectModel.BaseTypes.MaterialControl
{
    using System;

    using Preactor.ObjectModel.Attributes;
    using Preactor.ObjectModel.Entities;
    using Preactor.ObjectModel.Interfaces.MaterialControl;

    public class Supply : PreactorRecord, ISupply
    {
        public Supply(PrimaryKey id, PreactorObjectModel preactorObjectModel)
            : base(id, preactorObjectModel)
        {
        }

        [PreactorField("MATERIAL CONTROL ORDER NO", FieldDeclarationType.FieldClassification)]
        public string OrderNumber { get { return (string)GetValue("OrderNumber"); } set { SetValue("OrderNumber", value); } }

        [PreactorField("MATERIAL CONTROL PART NO", FieldDeclarationType.FieldClassification)]
        public string PartNumber { get { return (string)GetValue("PartNumber"); } set { SetValue("PartNumber", value); } }

        [PreactorField("SUPPLY DATE", FieldDeclarationType.FieldClassification)]
        public DateTime SupplyDate { get { return (DateTime)GetValue("SupplyDate"); } set { SetValue("SupplyDate", value); } }

        [PreactorField("PRIORITY", FieldDeclarationType.FieldClassification)]
        public int Priority { get { return (int)GetValue("Priority"); } set { SetValue("Priority", value); } }

        public double Quantity { get; set; }
    }
}
        